/*
    SUSAN® - Sole of Unix Save ANything

   Copyright (C) 2020-2020 Hechzh Property

   
*/
#ifndef BAREOS_SRC_DIRD_DBCOPY_ROW_DATA_H_
#define BAREOS_SRC_DIRD_DBCOPY_ROW_DATA_H_

#include "include/bareos.h"
#include "cats/column_data.h"
#include "dird/dbcopy/database_column_descriptions.h"

#include <vector>

class BareosDb;

struct RowData {
  RowData(const std::string& table_name_in,
          const DatabaseColumnDescriptions::ColumnDescriptions&
              column_descriptions_in)
      : table_name(table_name_in), column_descriptions(column_descriptions_in)
  {
    data_fields.resize(column_descriptions.size());
  }

  std::string table_name;

  std::vector<DatabaseField> data_fields;  // same index as column_descriptions
  const DatabaseColumnDescriptions::ColumnDescriptions& column_descriptions;

 public:
  ~RowData() = default;
  RowData(const RowData& other) = delete;
  RowData(RowData&& other) = delete;
  const RowData& operator=(const RowData& rhs) = delete;
  const RowData& operator=(RowData&& rhs) = delete;
};

#endif  // BAREOS_SRC_DIRD_DBCOPY_ROW_DATA_H_
